package org.openems.otdr;

import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.QueryParam;
import javax.ws.rs.core.MediaType;

import org.openems.PrimitiveTraceEntity;

@Path("/otdrFileJson")
public class OtdrTraceJsonResource {
    @GET
    @Produces(MediaType.APPLICATION_JSON)
    public PrimitiveTraceEntity get(@QueryParam("key") String key, @QueryParam("points") String points) {
        return new OtdrTrace().get(key, Integer.valueOf(points));
    }
}
